\(\int (d \cot (e+f x))^n \csc ^6(e+f x) \, dx\) [43]

   Optimal result
   Rubi [A] (verified)
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [A] (verification not implemented)
   Sympy [F(-1)]
   Maxima [A] (verification not implemented)
   Giac [F]
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 19, antiderivative size = 76 \[ \int (d \cot (e+f x))^n \csc ^6(e+f x) \, dx=-\frac {(d \cot (e+f x))^{1+n}}{d f (1+n)}-\frac {2 (d \cot (e+f x))^{3+n}}{d^3 f (3+n)}-\frac {(d \cot (e+f x))^{5+n}}{d^5 f (5+n)} \]

[Out]

-(d*cot(f*x+e))^(1+n)/d/f/(1+n)-2*(d*cot(f*x+e))^(3+n)/d^3/f/(3+n)-(d*cot(f*x+e))^(5+n)/d^5/f/(5+n)

Rubi [A] (verified)

Time = 0.09 (sec) , antiderivative size = 76, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.105, Rules used = {2687, 276} \[ \int (d \cot (e+f x))^n \csc ^6(e+f x) \, dx=-\frac {(d \cot (e+f x))^{n+5}}{d^5 f (n+5)}-\frac {2 (d \cot (e+f x))^{n+3}}{d^3 f (n+3)}-\frac {(d \cot (e+f x))^{n+1}}{d f (n+1)} \]

[In]

Int[(d*Cot[e + f*x])^n*Csc[e + f*x]^6,x]

[Out]

-((d*Cot[e + f*x])^(1 + n)/(d*f*(1 + n))) - (2*(d*Cot[e + f*x])^(3 + n))/(d^3*f*(3 + n)) - (d*Cot[e + f*x])^(5
 + n)/(d^5*f*(5 + n))

Rule 276

Int[((c_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*(a + b*x^n)^p,
 x], x] /; FreeQ[{a, b, c, m, n}, x] && IGtQ[p, 0]

Rule 2687

Int[sec[(e_.) + (f_.)*(x_)]^(m_)*((b_.)*tan[(e_.) + (f_.)*(x_)])^(n_.), x_Symbol] :> Dist[1/f, Subst[Int[(b*x)
^n*(1 + x^2)^(m/2 - 1), x], x, Tan[e + f*x]], x] /; FreeQ[{b, e, f, n}, x] && IntegerQ[m/2] &&  !(IntegerQ[(n
- 1)/2] && LtQ[0, n, m - 1])

Rubi steps \begin{align*} \text {integral}& = \frac {\text {Subst}\left (\int (-d x)^n \left (1+x^2\right )^2 \, dx,x,-\cot (e+f x)\right )}{f} \\ & = \frac {\text {Subst}\left (\int \left ((-d x)^n+\frac {2 (-d x)^{2+n}}{d^2}+\frac {(-d x)^{4+n}}{d^4}\right ) \, dx,x,-\cot (e+f x)\right )}{f} \\ & = -\frac {(d \cot (e+f x))^{1+n}}{d f (1+n)}-\frac {2 (d \cot (e+f x))^{3+n}}{d^3 f (3+n)}-\frac {(d \cot (e+f x))^{5+n}}{d^5 f (5+n)} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.65 (sec) , antiderivative size = 73, normalized size of antiderivative = 0.96 \[ \int (d \cot (e+f x))^n \csc ^6(e+f x) \, dx=-\frac {\left (8+6 n+n^2-2 (3+n) \cos (2 (e+f x))+\cos (4 (e+f x))\right ) \cot (e+f x) (d \cot (e+f x))^n \csc ^4(e+f x)}{f (1+n) (3+n) (5+n)} \]

[In]

Integrate[(d*Cot[e + f*x])^n*Csc[e + f*x]^6,x]

[Out]

-(((8 + 6*n + n^2 - 2*(3 + n)*Cos[2*(e + f*x)] + Cos[4*(e + f*x)])*Cot[e + f*x]*(d*Cot[e + f*x])^n*Csc[e + f*x
]^4)/(f*(1 + n)*(3 + n)*(5 + n)))

Maple [A] (verified)

Time = 23.14 (sec) , antiderivative size = 90, normalized size of antiderivative = 1.18

method result size
derivativedivides \(-\frac {\cot \left (f x +e \right ) {\mathrm e}^{n \ln \left (d \cot \left (f x +e \right )\right )}}{f \left (1+n \right )}-\frac {2 \cot \left (f x +e \right )^{3} {\mathrm e}^{n \ln \left (d \cot \left (f x +e \right )\right )}}{f \left (3+n \right )}-\frac {\cot \left (f x +e \right )^{5} {\mathrm e}^{n \ln \left (d \cot \left (f x +e \right )\right )}}{f \left (5+n \right )}\) \(90\)
default \(-\frac {\cot \left (f x +e \right ) {\mathrm e}^{n \ln \left (d \cot \left (f x +e \right )\right )}}{f \left (1+n \right )}-\frac {2 \cot \left (f x +e \right )^{3} {\mathrm e}^{n \ln \left (d \cot \left (f x +e \right )\right )}}{f \left (3+n \right )}-\frac {\cot \left (f x +e \right )^{5} {\mathrm e}^{n \ln \left (d \cot \left (f x +e \right )\right )}}{f \left (5+n \right )}\) \(90\)
risch \(\text {Expression too large to display}\) \(10532\)

[In]

int((d*cot(f*x+e))^n*csc(f*x+e)^6,x,method=_RETURNVERBOSE)

[Out]

-1/f/(1+n)*cot(f*x+e)*exp(n*ln(d*cot(f*x+e)))-2/f/(3+n)*cot(f*x+e)^3*exp(n*ln(d*cot(f*x+e)))-1/f/(5+n)*cot(f*x
+e)^5*exp(n*ln(d*cot(f*x+e)))

Fricas [A] (verification not implemented)

none

Time = 0.27 (sec) , antiderivative size = 145, normalized size of antiderivative = 1.91 \[ \int (d \cot (e+f x))^n \csc ^6(e+f x) \, dx=-\frac {{\left (8 \, \cos \left (f x + e\right )^{5} - 4 \, {\left (n + 5\right )} \cos \left (f x + e\right )^{3} + {\left (n^{2} + 8 \, n + 15\right )} \cos \left (f x + e\right )\right )} \left (\frac {d \cos \left (f x + e\right )}{\sin \left (f x + e\right )}\right )^{n}}{{\left ({\left (f n^{3} + 9 \, f n^{2} + 23 \, f n + 15 \, f\right )} \cos \left (f x + e\right )^{4} + f n^{3} + 9 \, f n^{2} - 2 \, {\left (f n^{3} + 9 \, f n^{2} + 23 \, f n + 15 \, f\right )} \cos \left (f x + e\right )^{2} + 23 \, f n + 15 \, f\right )} \sin \left (f x + e\right )} \]

[In]

integrate((d*cot(f*x+e))^n*csc(f*x+e)^6,x, algorithm="fricas")

[Out]

-(8*cos(f*x + e)^5 - 4*(n + 5)*cos(f*x + e)^3 + (n^2 + 8*n + 15)*cos(f*x + e))*(d*cos(f*x + e)/sin(f*x + e))^n
/(((f*n^3 + 9*f*n^2 + 23*f*n + 15*f)*cos(f*x + e)^4 + f*n^3 + 9*f*n^2 - 2*(f*n^3 + 9*f*n^2 + 23*f*n + 15*f)*co
s(f*x + e)^2 + 23*f*n + 15*f)*sin(f*x + e))

Sympy [F(-1)]

Timed out. \[ \int (d \cot (e+f x))^n \csc ^6(e+f x) \, dx=\text {Timed out} \]

[In]

integrate((d*cot(f*x+e))**n*csc(f*x+e)**6,x)

[Out]

Timed out

Maxima [A] (verification not implemented)

none

Time = 0.25 (sec) , antiderivative size = 84, normalized size of antiderivative = 1.11 \[ \int (d \cot (e+f x))^n \csc ^6(e+f x) \, dx=-\frac {\frac {\left (\frac {d}{\tan \left (f x + e\right )}\right )^{n + 1}}{d {\left (n + 1\right )}} + \frac {2 \, d^{n} \tan \left (f x + e\right )^{-n}}{{\left (n + 3\right )} \tan \left (f x + e\right )^{3}} + \frac {d^{n} \tan \left (f x + e\right )^{-n}}{{\left (n + 5\right )} \tan \left (f x + e\right )^{5}}}{f} \]

[In]

integrate((d*cot(f*x+e))^n*csc(f*x+e)^6,x, algorithm="maxima")

[Out]

-((d/tan(f*x + e))^(n + 1)/(d*(n + 1)) + 2*d^n*tan(f*x + e)^(-n)/((n + 3)*tan(f*x + e)^3) + d^n*tan(f*x + e)^(
-n)/((n + 5)*tan(f*x + e)^5))/f

Giac [F]

\[ \int (d \cot (e+f x))^n \csc ^6(e+f x) \, dx=\int { \left (d \cot \left (f x + e\right )\right )^{n} \csc \left (f x + e\right )^{6} \,d x } \]

[In]

integrate((d*cot(f*x+e))^n*csc(f*x+e)^6,x, algorithm="giac")

[Out]

integrate((d*cot(f*x + e))^n*csc(f*x + e)^6, x)

Mupad [B] (verification not implemented)

Time = 13.36 (sec) , antiderivative size = 123, normalized size of antiderivative = 1.62 \[ \int (d \cot (e+f x))^n \csc ^6(e+f x) \, dx=-\frac {{\left (\frac {d\,\cos \left (e+f\,x\right )}{2\,\cos \left (\frac {e}{2}+\frac {f\,x}{2}\right )\,\sin \left (\frac {e}{2}+\frac {f\,x}{2}\right )}\right )}^n\,\left (5\,\cos \left (e+f\,x\right )-\frac {5\,\cos \left (3\,e+3\,f\,x\right )}{2}+\frac {\cos \left (5\,e+5\,f\,x\right )}{2}+5\,n\,\cos \left (e+f\,x\right )-n\,\cos \left (3\,e+3\,f\,x\right )+n^2\,\cos \left (e+f\,x\right )\right )}{f\,{\sin \left (e+f\,x\right )}^5\,\left (n+1\right )\,\left (n+3\right )\,\left (n+5\right )} \]

[In]

int((d*cot(e + f*x))^n/sin(e + f*x)^6,x)

[Out]

-(((d*cos(e + f*x))/(2*cos(e/2 + (f*x)/2)*sin(e/2 + (f*x)/2)))^n*(5*cos(e + f*x) - (5*cos(3*e + 3*f*x))/2 + co
s(5*e + 5*f*x)/2 + 5*n*cos(e + f*x) - n*cos(3*e + 3*f*x) + n^2*cos(e + f*x)))/(f*sin(e + f*x)^5*(n + 1)*(n + 3
)*(n + 5))